﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="AdminAdd.aspx.cs" Inherits="BackGround_AdminAdd" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <table>
            <tr>
                <td style="width: 100px; text-align: right;">
                    用 户 名:&nbsp;
                </td>
                <td style="color: red;">
                    <asp:TextBox ID="name" runat="server" Width="120px" MaxLength="9"></asp:TextBox>
                    *
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="name"
                        Display="Dynamic" ErrorMessage="用户名不能为空" ValidationGroup="v1"></asp:RequiredFieldValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ControlToValidate="name"
                        ErrorMessage="用户名必须是2-9位数字或字母或它们的组合" ValidationExpression="[a-zA-Z0-9]{2,9}"></asp:RegularExpressionValidator>
                </td>
            </tr>
            <tr>
                <td style="width: 100px; text-align: right;">
                    密 &nbsp;&nbsp;码:&nbsp;
                </td>
                <td style="color: red;">
                    <asp:TextBox ID="password" runat="server" TextMode="Password" Width="120px" MaxLength="20"></asp:TextBox>
                    *
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="password"
                        Display="Dynamic" ErrorMessage="密码不能为空" ValidationGroup="v1"></asp:RequiredFieldValidator>
                    &nbsp;
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator3" runat="server" ControlToValidate="password"
                        ErrorMessage="密码必须为6-20位字母、数字或它们的组合" ValidationExpression="[a-zA-Z0-9]{6,20}"
                        ValidationGroup="v1"></asp:RegularExpressionValidator>
                </td>
            </tr>
            <tr>
                <td style="width: 100px; text-align: right;">
                    &nbsp; &nbsp; &nbsp; 确认密码:&nbsp;
                </td>
                <td style="color: red;">
                    <asp:TextBox ID="TB3" runat="server" TextMode="Password" Width="120px"></asp:TextBox>
                    *
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="TB3"
                        Display="Dynamic" ErrorMessage="确认密码不能为空" ValidationGroup="v1"></asp:RequiredFieldValidator>
                    <asp:CompareValidator ID="CompareValidator1" runat="server" ControlToCompare="password"
                        ControlToValidate="TB3" Display="Dynamic" ErrorMessage="密码不一致" ValidationGroup="v1"></asp:CompareValidator>
                </td>
            </tr>
            <tr><td></td>
            <td><asp:Button ID="btOK" runat="server" Text="确定" ValidationGroup="v1" 
                    onclick="btOK_Click" />
                        </td></tr>
        </table>
    </div>
    </form>
</body>
</html>
